<ul class="nav nav-tabs nav-header-section cd-mt24 clearfix">
  {% if not is_un_multi_courseset(courseSet.id) %}
    <li class="nav-header-section__item cd-ml32 {% if side_nav == 'base' %}active{% endif %}">
      {% if courseSet.locked %}
        <a href="{{ path('course_set_manage_sync', {id: courseSet.id, sideNav: 'base'}) }}">
          <span class="es-icon es-icon-lock mr10" aria-hidden="true"></span>{{ 'course.base'|trans }}
        </a>
      {% else %}
        <a href="{{ path('course_set_manage_base', {id: courseSet.id}) }}">{{ 'course.base'|trans }}</a>
      {% endif %}
    </li>
    {% if not has_mul_courses(courseSet.id) %}
      <div class="pull-left nav-header-section-step" id="step-2">
        <li class="nav-header-section__item {% if side_nav == 'default-course-info' %}active{% endif %}">
          {% if courseSet.locked %}
            <a class="nav-header-section__link" href="{{ path('course_set_manage_course_students', {courseSetId: courseSet.id, courseId: courseSet.defaultCourseId}) }}">{{ 'site.default.plan_setting'|trans }}</a>
          {% else %}
            <a class="nav-header-section__link" href="{{ path('course_set_manage_course_info', {courseSetId: courseSet.id, courseId: courseSet.defaultCourseId}) }}">{{ 'site.default.plan_setting'|trans }}</a>
          {% endif %}
        </li>
      </div>
    {% endif %}
    <div class="pull-left nav-header-section-step" id="step-3">
      <li class="nav-header-section__item {% if side_nav == 'plan' %}active{% endif %}">
        {% if courseSet.locked %}
          <a class="nav-header-section__link" href="{{ path('course_set_manage_course_students', {courseSetId: courseSet.id, courseId: courseSet.defaultCourseId}) }}">
            {{ 'course.teach_plan_manage'|trans }}
          </a>
        {% elseif courseSet.type == 'live' %}
          <a class="nav-header-section__link" href="{{ path('course_set_manage_course_tasks', {courseSetId: courseSet.id, courseId: courseSet.defaultCourseId}) }}">{{ 'course.teach_plan_manage'|trans }}</a>
        {% else %}
          <a class="nav-header-section__link" href="{{ path('course_set_manage_courses', {courseSetId: courseSet.id}) }}">{{ 'course.filter.all_plan'|trans }}</a>
        {% endif %}
      </li>
    </div>
  {% else %}
    <li class="nav-header-section__item {% if side_nav == 'default-course-info' %}active{% endif %}">
      {% if courseSet.locked %}
        <a class="nav-header-section__link" href="{{ path('course_set_manage_course_students', {courseSetId: courseSet.id, courseId: courseSet.defaultCourseId}) }}">{{ 'courseset.setup'|trans }}</a>
      {% else %}
        <a class="nav-header-section__link" href="{{ path('course_set_manage_course_info', {courseSetId: courseSet.id, courseId: courseSet.defaultCourseId}) }}">{{ 'courseset.setup'|trans }}</a>
      {% endif %}
    </li>
  {% endif %}

  <div class="clearfix nav-header-section-step" id="step-1">
    <li class="nav-header-section__item pull-right cd-mr32 {% if side_nav == 'question' %}active{% endif %}">
      {% if courseSet.locked %}
        <a href="{{ path('course_set_manage_sync', {id: courseSet.id, sideNav: 'question'}) }}">
          <span class="es-icon es-icon-lock mr10" aria-hidden="true"></span>{{ 'course.question_manage'|trans }}
        </a>
      {% else %}
        <a href="{{ path('course_set_manage_question', {id: courseSet.id}) }}">
          {{ 'course.question_manage'|trans }}
        </a>
      {% endif %}
    </li>

    <li class="nav-header-section__item pull-right {% if side_nav == 'testpaper' %}active{% endif %}" data-intro-group="odd">
      {% if courseSet.locked %}
        <a href="{{ path('course_set_manage_sync', {id: courseSet.id, sideNav: 'testpaper'}) }}">
          <span class="es-icon es-icon-lock mr10" aria-hidden="true"></span>{{ 'course.testpaper_manage'|trans }}
        </a>
      {% else %}
        <a href="{{ path('course_set_manage_testpaper', {id: courseSet.id}) }}">
          {{ 'course.testpaper_manage'|trans }}
        </a>
      {% endif %}
    </li>

    <li class="nav-header-section__item pull-right cd-ml24 {% if side_nav == 'files' %}active{% endif %}" data-intro-group="odd">
      {% if courseSet.locked %}
        <a href="{{ path('course_set_manage_sync', {id: courseSet.id, sideNav: 'files'}) }}">
          <span class="es-icon es-icon-lock mr10" aria-hidden="true"></span>{{ 'course.course_files'|trans }}
        </a>
      {% else %}
        <a href="{{ path('course_set_manage_files', {id: courseSet.id}) }}">{{ 'course.course_files'|trans }}</a>
      {% endif %}
    </li>
  </div>

  {{ slot('course_set.menu.extension', {'courseSet':courseSet,'sideNav':side_nav}) }}
</ul>